package cn.vshare.service;

import cn.vshare.entity.Reply;
import cn.vshare.entity.User;
import com.github.pagehelper.PageInfo;

/**
 * @Auther: 张恒
 * @Date: 2018/9/18 16:17
 * @Description:replyService接口
 */
public interface ReplyService {
    /**
     * 分页显示回复
      * @param commentId
     * @param pageNum
     * @param pageSize
     * @return boolean
     */
    PageInfo<Reply> queryAllReply(String commentId, Integer pageNum, Integer pageSize);

    /**
     *插入成功时,返回插入成功的replyId方便查到新插入的该对象
     * @param user
     * @param commentId
     * @param context
     * @return boolean
     */
    Reply addReply(User user, User toUser, String commentId, String context, String date);

    boolean delReply(String replyId);

    boolean updateReplyAuditStatus(String replyId, Integer auditStatus);

    boolean updateReplyByInform(String replyId);

    boolean updateReplyAddLike(User user, String replyId) throws Exception;

    boolean updateReplyCancelLike(User user, String replyId) throws Exception;

    Reply queryReplyById(String replyId);

    int queryReplyIfLike(String replyId, User user);

    boolean updateReplyParseCount(String replyId, Integer parseCount);



}
